<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        let arr = [1,2,3,4,5,6];
        
        // 解构
        console.log('[...arr]:',[...arr]);

        // Array.from()方法
        console.log('Array.from(arr):',Array.from(arr));

        // slice方法
        console.log('arr.slice():',arr.slice());

        // map方法重构数据
        console.log('arr.map(v => v):',arr.map(v => v));

        // filter方法
        console.log('arr.filter(v => true):',arr.filter(v => true));

        // Object.assign()方法
        console.log('Object.assign([],arr):',Object.assign([],arr));
    </script>
</body>
</html>